package org.cloud.model.entity;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author author
 * @since 2024-04-15
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("t_account")
@AllArgsConstructor
@NoArgsConstructor
@Schema(title = "账户表")
public class Account implements Serializable {

    private static final long serialVersionUID = 1L;

    @Schema(title = "id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @Schema(title = "用户id")
    private Long userId;

    @Schema(title = "总额度")
    private BigDecimal total;

    @Schema(title = "已用账户余额")
    private BigDecimal used;

    @Schema(title = "剩余可用额度")
    private BigDecimal residue;
}
